cc.Class({
    extends: cc.Component,

    properties: {
        logo:{
            type:cc.Sprite,
            default:null
        },
    },

    // LIFE-CYCLE CALLBACKS:

    onLoad () {
        let self = this;
        let remoteUrl = "https://scratch-web.oss-cn-hangzhou.aliyuncs.com/schoolres/"+window.location.hostname+"/logo.png";
        cc.loader.load(remoteUrl, function (err, texture) {
            if (err) {
                cc.error(err);
            } else {
                self.logo.spriteFrame = new cc.SpriteFrame(texture);
            }
        });
    },

    // start () {
    // },

    // update (dt) {},

    reset() {
        cc.director.loadScene("scene"+Data.current);
    }
});
